package com.yl.chainStore.mapper.sick

import com.yl.chainStore.entity.sick.SickCustomerAccessLog;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page
import com.yl.chainStore.common.enums.TypeEnum
import com.yl.chainStore.pojo.vo.sick.SickCustomerAccessLogSelectVo
import org.apache.ibatis.annotations.Mapper
import org.apache.ibatis.annotations.Param

/**
 * <p>
 * 用户随访记录 Mapper 接口
 * </p>
 *
 * @author cxw
 * @since 2021-07-10
 */
@Mapper
interface SickCustomerAccessLogMapper : BaseMapper<SickCustomerAccessLog> {

	/**
	 * 分页查询
	 */
	fun getLogPage(
		@Param("page") page: Page<SickCustomerAccessLog>,
		@Param("vo") vo: SickCustomerAccessLogSelectVo
	): Page<SickCustomerAccessLog>

	/**
	 * 查询列表
	 */
	fun getLogList(
		@Param("vo") vo: SickCustomerAccessLogSelectVo
	): List<SickCustomerAccessLog>

	/**
	 * 查询数量
	 */
	fun getLogCount(@Param("vo") vo: SickCustomerAccessLogSelectVo): Int

	/**
	 * 获取今日随访人员
	 */
	fun getTodayNewAccessLog(@Param("deptId") deptId: Long): Int

	/**
	 * 获取今日随访人员
	 */
	fun getTodayNewAccessLogByUserId(@Param("userId") userId: Long): Int


}
